<template>
  <router-view/>
</template>

<script>
import Events from "./events/Events";
import {useUserLogin} from "./hooks/user/useUserLogin";

export default {
  setup() {
    const loginHandle = useUserLogin();
    // 监听其它子组件的刷新用户信息事件
    window.emitter.on(Events.refreshUserInfo, () => {
      loginHandle.initUserInfo2Vuex(false)
    });
  }
};
</script>

<style lang="scss">
@import "./assets/css/main.css";
@import "./assets/css/color-dark.css";

</style>
